#pragma once
#include <map>

using namespace std;


class TimerHandle
{
public:
    TimerHandle(){};
    virtual ~TimerHandle(){};
    virtual void processTimeOut(int cmd) = 0; 
};


class BSTimer
{
public:
    BSTimer();
    ~BSTimer();

    void setHandle(int cmd , TimerHandle* pHandle);
    int startTimer(int seconds);
    int stopTimer();
    void processTimer();

private:
    unsigned        m_id;
    int             m_cmd;
    TimerHandle*    m_pTimerHanle;
};
